<?php
class LinksModel extends Model
{
	var $_validate = array(
		array('link_url','require','友情链接URL不能为空！',MUST_TO_VALIDATE),
		array('link_name','require','友情链接名称不能为空！',MUST_TO_VALIDATE),
	);

	var $_auto = array(
		array('link_description','getDesrc' ,'ALL','callback')
	);
	
	function getDesrc()
	{
		return empty($_POST["link_description"])?$_POST["link_name"]:$_POST["link_description"];
	}
}
?>